/* Returns the Square of a number */
parse arg input                 /* get the number to square from user */

value = .squared~new                    /* create an object for a squared value */
sqd = value~square(input)               /* invoke SQUARE method on INPUT value */

say 'The original value:' input 'squared is:' sqd
exit 0          /* cause the exit of the program */

::class squared
        ::method 'square'              /* Class SQUARED has 1 method, SQUARE */
        use arg in                     /* get input argument */
        return ( in * in )             /* Square it and return that value */